intrange (parameter type)

An integer range is specified with type="intrange" in the parameter definition:

    {name="MyIntRange", type="intrange", range={0, 100}, default={10, 90}}

The range is represented by a slider in the UI, with two handles for adjusting the lower and upper value:

../../../_images/ui-intrange-parameter.png

The valid value increments can be specified with ui={stepSize=<value>}:

    {name="MySteppedIntRange", type="intrange", range={0, 100}, ui={stepSize=5}}

The current range is accessed via self.parameters in the execute method which provides a Lua array with two Lua numbers:

  local myIntRange = self.parameters.MyIntRange
  local lowerInt = myIntRange[1]
  local upperInt = myIntRange[2]